<button type="button" class="btn btn-default addterminal" *ngIf="edited" (click)="addtr()">
  <span class="glyphicon glyphicon-plus"></span>终端
</button>
<small class="error" *ngIf="expressionError&&!_data[0]['terminalCode']">请输入至少一个终端</small>
<div class="table-header">
  <table class="table table-bordered table-header game-table">
    <thead>
      <tr>
        <td class="w5 text-center">序号</td>
        <td class="w10 text-center">终端</td>
        <td class="w30 text-center">资源地址</td>
        <td class="w10 text-center">开放版本</td>
        <td class="w10 text-center">加密版本</td>
        <td class="w10 text-center">加密密码</td>
        <td class="w10 text-center">DRM版本</td>
        <td class="w10 text-center">DRM密码</td>
        <td class="w5 text-center" *ngIf="edited">操作</td>
      </tr>
    </thead>
  </table>
</div>
<div class="table-body">
  <table class="table table-bordered table-header game-table">
    <tbody>
      <tr *ngFor="let tr of _data; let  i = index;" [ngClass]="{'active':i%2!=0}">
        <td class="w5 text-center">{{i+1}}</td>
        <td class="w10 text-center">
          <select name="terminalCode" [(ngModel)]="tr.terminalCode">
            <option value="">请选择</option>
            <option *ngFor="let item of terminaLists;" [value]='item.terminalCode'>{{item.terminalName}}</option>
          </select>
        </td>
        <td class="w30 text-center">
          <input class="form-control" name="uri" type="text" [(ngModel)]="tr.uri">
        </td>
        <td class="w10 text-center">
          <input class="form-control" name="uriType" type="text" [(ngModel)]="tr.uriType">
        </td>
        <td class="w10 text-center">
          <input class="form-control" name="passwordId" type="text" [(ngModel)]="tr.passwordId">
        </td>
        <td class="w10 text-center">
          <input class="form-control" name="password" type="text" [(ngModel)]="tr.password">
        </td>
        <td class="w10 text-center">
          <input class="form-control" name="drmId" type="text" [(ngModel)]="tr.drmId">
        </td>
        <td class="w10 text-center">
          <input class="form-control" name="drmPassword" type="text" [(ngModel)]="tr.drmPassword">
        </td>
        <td class="w20 text-center icon-td" *ngIf="edited">
          <i class="glyphicon glyphicon-trash cursor" (click)="deleteTr(i)"></i>
        </td>
      </tr>
    </tbody>
  </table>
</div>
